﻿using PMS.Core.Configuration.CommonEnumConfigs;
using PMS.Web.Framework.Models;

namespace PMS.Web.Models.Customers
{
    /// <summary>
    /// Represents a CustomerRole model with AdminRoleType
    /// </summary>
    public partial class AdminRoleModel : BaseEntityModel
    {
        #region Fields
        public string DisplayName { get; set; }

        /// <summary>
        /// 角色所属机构组织名称
        /// </summary>
        public int FKOrganizeId { get; set; }

        public RoleType RoleType { get; set; }
        /// <summary>
        /// 角色是否是超级管理员，超级管理员有绝对权限，无需验证角色对应模块判定授权状态
        /// </summary>
        public bool IsAdmin { get => RoleType == RoleType.Administrator; }

        public int DisplayOrder { get; set; }
        #endregion
    }
}
